#include "Texture.h"

namespace devii
{

Texture::Texture(const unsigned int width, const unsigned int height)
{
	this->width = width;
	this->height = height;
	texture = NULL;
	texture_buffer = NULL;
}

Texture::~Texture()
{
	if(texture)
		texture->Release();
	if(texture_buffer)
		texture_buffer->Release();
}

void Texture::setTexture(ID3D11Texture2D * const texture)
{
	this->texture = texture;
}


void Texture::setTextureBuffer(ID3D11ShaderResourceView * const texture_buffer)
{
	this->texture_buffer = texture_buffer;
}

ID3D11Texture2D * Texture::getTexture()
{
	return texture;
}

ID3D11ShaderResourceView * Texture::getTextureBuffer()
{
	return texture_buffer;
}

}